package xian.woniuxy.hisbe.entity;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class AppointmentExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public AppointmentExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andAppoIdIsNull() {
            addCriterion("appo_id is null");
            return (Criteria) this;
        }

        public Criteria andAppoIdIsNotNull() {
            addCriterion("appo_id is not null");
            return (Criteria) this;
        }

        public Criteria andAppoIdEqualTo(Integer value) {
            addCriterion("appo_id =", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdNotEqualTo(Integer value) {
            addCriterion("appo_id <>", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdGreaterThan(Integer value) {
            addCriterion("appo_id >", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("appo_id >=", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdLessThan(Integer value) {
            addCriterion("appo_id <", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdLessThanOrEqualTo(Integer value) {
            addCriterion("appo_id <=", value, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdIn(List<Integer> values) {
            addCriterion("appo_id in", values, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdNotIn(List<Integer> values) {
            addCriterion("appo_id not in", values, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdBetween(Integer value1, Integer value2) {
            addCriterion("appo_id between", value1, value2, "appoId");
            return (Criteria) this;
        }

        public Criteria andAppoIdNotBetween(Integer value1, Integer value2) {
            addCriterion("appo_id not between", value1, value2, "appoId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdIsNull() {
            addCriterion("schedule_id is null");
            return (Criteria) this;
        }

        public Criteria andScheduleIdIsNotNull() {
            addCriterion("schedule_id is not null");
            return (Criteria) this;
        }

        public Criteria andScheduleIdEqualTo(Integer value) {
            addCriterion("schedule_id =", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdNotEqualTo(Integer value) {
            addCriterion("schedule_id <>", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdGreaterThan(Integer value) {
            addCriterion("schedule_id >", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("schedule_id >=", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdLessThan(Integer value) {
            addCriterion("schedule_id <", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdLessThanOrEqualTo(Integer value) {
            addCriterion("schedule_id <=", value, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdIn(List<Integer> values) {
            addCriterion("schedule_id in", values, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdNotIn(List<Integer> values) {
            addCriterion("schedule_id not in", values, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdBetween(Integer value1, Integer value2) {
            addCriterion("schedule_id between", value1, value2, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andScheduleIdNotBetween(Integer value1, Integer value2) {
            addCriterion("schedule_id not between", value1, value2, "scheduleId");
            return (Criteria) this;
        }

        public Criteria andDocIdIsNull() {
            addCriterion("doc_id is null");
            return (Criteria) this;
        }

        public Criteria andDocIdIsNotNull() {
            addCriterion("doc_id is not null");
            return (Criteria) this;
        }

        public Criteria andDocIdEqualTo(Integer value) {
            addCriterion("doc_id =", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdNotEqualTo(Integer value) {
            addCriterion("doc_id <>", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdGreaterThan(Integer value) {
            addCriterion("doc_id >", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("doc_id >=", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdLessThan(Integer value) {
            addCriterion("doc_id <", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdLessThanOrEqualTo(Integer value) {
            addCriterion("doc_id <=", value, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdIn(List<Integer> values) {
            addCriterion("doc_id in", values, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdNotIn(List<Integer> values) {
            addCriterion("doc_id not in", values, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdBetween(Integer value1, Integer value2) {
            addCriterion("doc_id between", value1, value2, "docId");
            return (Criteria) this;
        }

        public Criteria andDocIdNotBetween(Integer value1, Integer value2) {
            addCriterion("doc_id not between", value1, value2, "docId");
            return (Criteria) this;
        }

        public Criteria andPatIdIsNull() {
            addCriterion("pat_id is null");
            return (Criteria) this;
        }

        public Criteria andPatIdIsNotNull() {
            addCriterion("pat_id is not null");
            return (Criteria) this;
        }

        public Criteria andPatIdEqualTo(Integer value) {
            addCriterion("pat_id =", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdNotEqualTo(Integer value) {
            addCriterion("pat_id <>", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdGreaterThan(Integer value) {
            addCriterion("pat_id >", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("pat_id >=", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdLessThan(Integer value) {
            addCriterion("pat_id <", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdLessThanOrEqualTo(Integer value) {
            addCriterion("pat_id <=", value, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdIn(List<Integer> values) {
            addCriterion("pat_id in", values, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdNotIn(List<Integer> values) {
            addCriterion("pat_id not in", values, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdBetween(Integer value1, Integer value2) {
            addCriterion("pat_id between", value1, value2, "patId");
            return (Criteria) this;
        }

        public Criteria andPatIdNotBetween(Integer value1, Integer value2) {
            addCriterion("pat_id not between", value1, value2, "patId");
            return (Criteria) this;
        }

        public Criteria andDepartIdIsNull() {
            addCriterion("depart_id is null");
            return (Criteria) this;
        }

        public Criteria andDepartIdIsNotNull() {
            addCriterion("depart_id is not null");
            return (Criteria) this;
        }

        public Criteria andDepartIdEqualTo(Integer value) {
            addCriterion("depart_id =", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdNotEqualTo(Integer value) {
            addCriterion("depart_id <>", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdGreaterThan(Integer value) {
            addCriterion("depart_id >", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("depart_id >=", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdLessThan(Integer value) {
            addCriterion("depart_id <", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdLessThanOrEqualTo(Integer value) {
            addCriterion("depart_id <=", value, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdIn(List<Integer> values) {
            addCriterion("depart_id in", values, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdNotIn(List<Integer> values) {
            addCriterion("depart_id not in", values, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdBetween(Integer value1, Integer value2) {
            addCriterion("depart_id between", value1, value2, "departId");
            return (Criteria) this;
        }

        public Criteria andDepartIdNotBetween(Integer value1, Integer value2) {
            addCriterion("depart_id not between", value1, value2, "departId");
            return (Criteria) this;
        }

        public Criteria andAppoIspayIsNull() {
            addCriterion("appo_ispay is null");
            return (Criteria) this;
        }

        public Criteria andAppoIspayIsNotNull() {
            addCriterion("appo_ispay is not null");
            return (Criteria) this;
        }

        public Criteria andAppoIspayEqualTo(Boolean value) {
            addCriterion("appo_ispay =", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayNotEqualTo(Boolean value) {
            addCriterion("appo_ispay <>", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayGreaterThan(Boolean value) {
            addCriterion("appo_ispay >", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayGreaterThanOrEqualTo(Boolean value) {
            addCriterion("appo_ispay >=", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayLessThan(Boolean value) {
            addCriterion("appo_ispay <", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayLessThanOrEqualTo(Boolean value) {
            addCriterion("appo_ispay <=", value, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayIn(List<Boolean> values) {
            addCriterion("appo_ispay in", values, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayNotIn(List<Boolean> values) {
            addCriterion("appo_ispay not in", values, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayBetween(Boolean value1, Boolean value2) {
            addCriterion("appo_ispay between", value1, value2, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoIspayNotBetween(Boolean value1, Boolean value2) {
            addCriterion("appo_ispay not between", value1, value2, "appoIspay");
            return (Criteria) this;
        }

        public Criteria andAppoCommitIsNull() {
            addCriterion("appo_commit is null");
            return (Criteria) this;
        }

        public Criteria andAppoCommitIsNotNull() {
            addCriterion("appo_commit is not null");
            return (Criteria) this;
        }

        public Criteria andAppoCommitEqualTo(Date value) {
            addCriterion("appo_commit =", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitNotEqualTo(Date value) {
            addCriterion("appo_commit <>", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitGreaterThan(Date value) {
            addCriterion("appo_commit >", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitGreaterThanOrEqualTo(Date value) {
            addCriterion("appo_commit >=", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitLessThan(Date value) {
            addCriterion("appo_commit <", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitLessThanOrEqualTo(Date value) {
            addCriterion("appo_commit <=", value, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitIn(List<Date> values) {
            addCriterion("appo_commit in", values, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitNotIn(List<Date> values) {
            addCriterion("appo_commit not in", values, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitBetween(Date value1, Date value2) {
            addCriterion("appo_commit between", value1, value2, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoCommitNotBetween(Date value1, Date value2) {
            addCriterion("appo_commit not between", value1, value2, "appoCommit");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneIsNull() {
            addCriterion("appo_iscuredone is null");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneIsNotNull() {
            addCriterion("appo_iscuredone is not null");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneEqualTo(Boolean value) {
            addCriterion("appo_iscuredone =", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneNotEqualTo(Boolean value) {
            addCriterion("appo_iscuredone <>", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneGreaterThan(Boolean value) {
            addCriterion("appo_iscuredone >", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneGreaterThanOrEqualTo(Boolean value) {
            addCriterion("appo_iscuredone >=", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneLessThan(Boolean value) {
            addCriterion("appo_iscuredone <", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneLessThanOrEqualTo(Boolean value) {
            addCriterion("appo_iscuredone <=", value, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneIn(List<Boolean> values) {
            addCriterion("appo_iscuredone in", values, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneNotIn(List<Boolean> values) {
            addCriterion("appo_iscuredone not in", values, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneBetween(Boolean value1, Boolean value2) {
            addCriterion("appo_iscuredone between", value1, value2, "appoIscuredone");
            return (Criteria) this;
        }

        public Criteria andAppoIscuredoneNotBetween(Boolean value1, Boolean value2) {
            addCriterion("appo_iscuredone not between", value1, value2, "appoIscuredone");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}